package top.azusall.securitydemo.thread;


import top.azusall.securitydemo.common.MyUserDetail;

public class UserDetailThreadLocalUtil {
    private static final  ThreadLocal<MyUserDetail> threadLocal = new ThreadLocal<>();

    public static MyUserDetail get() {
        return threadLocal.get();
    }
    public static void set(MyUserDetail userDetail) {
        threadLocal.set(userDetail);
    }
    public static void remove() {
        threadLocal.remove();
    }
}
